#pragma once
#include <iostream>

// =============== Tire ===============
class Tire {
public:
	Tire() = default;

public:
	void Test() {
		std::cout << "Trie::Test()" << std::endl;
	}
};

// =============== Bottom ===============
class Bottom {
private:
	Tire tire;

public:
	// Tire Dependency Injection
	Bottom(const Tire& tire):
		tire(tire)
	{
	}

public:
	void Test() {
		tire.Test();
		std::cout << "Bottom::Test()" << std::endl;
	}
};

// =============== Body ===============
class Body {
private:
	Bottom bottom;

public:
	// Bottom Dependency Injection
	Body(const Bottom& bottom):
		bottom(bottom)
	{
	}

public:
	void Test() {
		std::cout << "Body::Test()" << std::endl;
	}
};

// =============== Car ===============
class Car {
private:
	Body body;

public:
	// Body Dependency Injection
	Car(const Body& body) :
		body(body)
	{
	}
public:
	void Test() {
		std::cout << "Body::Test()" << std::endl;
	}
};